home *** CD-ROM | disk | FTP | other *** search
- /****************************************************************/
- /******* NGI 1.2 DEMO *******************************************/
- /****************************************************************/
-
- An IFF, Workbench & C Utility by Kevin Bjorke
- Distributed by
- National Pixel Products
- 25724 Salceda Road
- Valencia, CA 91355
- CI$: 74756,464 PLink: OJS637
-
- This ARC File contains the DEMO version of NGI 1.2 --
- some functions have been disabled. For the real thing,
- plus complete source, send $25 to the above address --
- we'll get it right out to you.
-
- NGI is an Intuition-driven utility that will allow you to read, view, and
- reformat ILBM (DPaint, Aegis Images, DigiView, etc) pictures. Although NGI
- was originally intended to simply be a replacement for the "gi," "brush2c"
- & "brush2icon" utilities we'd been using (that didn't always work, alas),
- it's very useful as an IFF viewer, too -- it loads faster and is MUCH smaller
- than DPaint, and can show several pictures of most any reso during a single
- session -- so NGI is also an alternative to programs like "ShowILBM" and
- "DPaintX." NGI has been deliberately kept small enough so that you can just
- put it right on your normal DPaint disk. So even if you don't know what a BOB
- or ALTIMAGE is, don't write C code at all, and never need to make icons, NGI
- can still be a handy tool to have around your workbench.
-
- NGI 1.2 contains quite a few improvements and new options that make it
- superior to the original NGI -- NGI now can write Workbench icons, can
- handle twin-image gadgets, and lets you decide just what kind of final output
- you need. The NGI 1.2 Distribution Disk also contains some convenient C
- routines to help programmers make the most out of NGI with a minimum of fuss.
-
- /****************************************************************/
- /******* Instructions *******************************************/
- /****************************************************************/
-
- Of course the easiest way to learn how to use NGI is to fiddle with it -- but
- when in doubt, here's the straight scoop:
-
- /*** The Title Page ***/
-
- When you start up NGI (from CLI or Workbench), you'll first get the Title Page.
- Hit the BEGIN gadget to go to the Main Page, or hit the title to find out
- what you're doing.
-
- /*** The Main Page ***/
-
- The NGI Main Page has three string gadgets and three button gadgets, listed
- below. When you see the Main Page, you also have a number of menu selections
- available, and NGI will display information on any currently read-in brush.
-
- BRUSH: Enter the name of the brush you want to read. NGI can actually read any
- IFF file that it can cram into memory, so the "brush" may be a full-
- sized picture, even in hi-res.
-
- OUTPUT: If you use NGI to generate new C files or icons, enter the filename
- here. If you're writing an icon, don't bother with the ".info"
- suffix -- AmigaDOS will do it for you.
-
- STRUCT: If you use NGI to create C code, enter the name of the Image/Gadget/
- Bob/VSprite structure you want NGI to write.
-
- IMAGES, GELS, & ICONS: Selecting one of these buttons tells NGI what kind
- of file you want it to write -- selecting IMAGES tells NGI that
- you want to get C Source for Intuition-Style Images (and Gadgets);
- GELS says you want C Source for animation GELS; and ICONS says you
- want NGI to write a workbench icon instead of C code.
-
- THE STATUS LINE: The box just below the buttons is the status line. NGI
- will narrate whatever it's doing here -- for example, NGI announces
- each IFF chunk as it reads-in a brush.
-
- EXTRA INFO: The last three lines at the bottom of the screen will only
- appear if you've successfully read-in a brush-- they tell you which
- brush it is, its original name, size, and depth.
-
- /*** The Main Menus ***/
-
- PROJECT: From the Project Menu, you can Read, Display, & Save Brushes; get
- Help and other Information; and quit NGI (you can do this through the
- Close-Button on the NGI window at any time, too). All of the Project
- Menu selections have corresponding keyboard shortcuts.
-
- Read Brush: Try to read-in the brush named in BRUSH on the Main Page.
- Display: Display the currently read-in brush (See "The Display Page").
- Save: Save the current brush, according to the style selected by the
- IMAGES, GELS, or ICONS button, and with the various attributes
- set by the appropriate menu(s) (See Below).
- Help!!!: Get the Help Information Page.
- About: Get the About Information Page.
- Quit: Bye-Bye, Vamoose, OutaHere. NGI goes away.
-
- BRUSH: NGI can read more than one brush at the same time, providing there's
- some memory around for it. You can select which brush you're working
- on with this menu. If you make Gadgets or icons that use the "AltImage"
- feature, the brush that's selected (checked) will be the "normal"
- Image, while the non-selected brush will be the "hilight" Image.
-
- IMAGE: The Image Menu lets you format the C Source that NGI will write for
- dealing with Intuition Image and Gadget structures.
-
- Colors: If Colors are ON, then NGI will include in the output file
- an array of UWORD that represents the original brush colors.
- Use the "LoadRGB4()" function to set them up for your program.
- Gadgets: If Gadgets are ON, then NGI will write a boolean (button)
- Gadget that uses your Image(s).
- AltImage: If AltImage is ON, then IF [1] you've read two brushes, and
- have them both in memory (see the BRUSH Menu above); and
- [2] they're both the same size and the same depth; then NGI
- will write TWO Images into the same file -- and if Gadgets
- are on, the Gadget will use the unselected brush as its
- "SelectRender" -- the Image you see as the hilight when you
- click on the Gadget.
-
- GELS: The Gels Menu, like the Image Menu, lets you pick-and-choose Gel output
- parameters.
-
- Bob Colors: If Bob Colors are ON, then NGI will include in the output
- file an array of UWORD that represents the original brush
- colors whenever it writes a Bob (VSprite colors are built-in,
- and are a bit different anyway). Use "LoadRGB4()" to set them
- up for your program.
- VSprites: By default, NGI writes only Bobs. If you select Sprites, then
- NGI will write Gels as VSprites IF they're 16 or less pixels
- across and IF they're no more than two bitplanes deep. Otherwise
- you'll just get another Bob.
- Memory: The NGI 1.2 Disk contains a set of routines in "kGEL.c" that
- dynamically allocate Gels (these routines are for the most part
- the same as those in the popular "MyGelTools" routines, and
- are both Public Domain and widely available). If you choose
- Dynamic Memory, the output file will include "MakeVSprite()"
- or "MakeBob()" calls. If you chose Static Memory, the structures
- will be declared in-place.
-
- ICONS: The Icon Menu has only one option, "AltImage." It works like the
- "AltImage" option for Images: if selected, then when you try to write
- your icon: IF [1] you've read two brushes, and have them both in memory
- (see the BRUSH Menu above); and [2] they're both the same size and the
- same depth (which MUST be Depth=2 for icons); then NGI will write TWO
- Images into the same icon -- it will use the unselected brush as its
- "hilight" -- the Image you see when you click on the icon. If AltImage
- is OFF, then the highlight method is Backfill.
-
- /*** The Information Pages ***/
-
- The HELP and ABOUT pages are just there to tell you stuff. Hit "OK" to return
- to the Main Page (or the Close button to Give Up Altogether).
-
- /*** The Display Page ***/
-
- When you select Show Brush (Amiga-D), NGI will try to set up a new screen and
- show you the current brush. Normally it will make the screen lo-res if the
- brush will fit -- but if you've selected ICONS as the output style (even if
- you have no intention of writing icons), the screen will come up with 640-pixel
- width, just like the workbench. If your picture is bigger than 640 across or
- 400 high, tough -- that's all you'll see. (But who would want to code an Image
- that big without compression, anyway?)
-
- The display page has a short menu:
-
- WBColors: If your picture only has a couple of bit planes, you can
- override the original brush colors to see what it would look
- like on the workbench.
- Other Brush: If you have two brushes read-in with the same size and
- depth, you can toggle between them, for an AltImage preview.
- End Display: Closes the Display and sends you back to the Main Page.
-
- /****************************************************************/
- /******* The Future *********************************************/
- /****************************************************************/
-
- Future Enhancements to NGI may or may not include:
-
- 1. Easier file specification that using the string gadget to type something like
- "pictures12:brush/wb-brushes/NewCLick.Brush" -- probably some sort of
- file requester a la DPaint.
-
- 2. More Brushes. If NGI could read more brushes (not a hard thing to do), it
- could potentially create and preview multi-Bob AnimComps. Since
- animation development is what NGI was built for in the first place, this
- is a high priority. Everyone HATES doing repetitive stuff. At the same
- time, maybe it's overkill, especially with dynamically-allocated Bobs.
-
- 3. Mask/Stencil Planes. Since Image structures don't use Mask planes, NGI
- doesn't bother with them. They can sometimes be handy for animation,
- however. (Yes, we know about Masked Gadgets. But DPaint doesn't
- store BRUSHES that way...)
-
- 4. Basic? NGI could also write BASIC "objects," if we ever got requests for
- that sort of thing. Probably lots of requests.
-
- 5. Special CLI options in addition to the mouse. It might be handy to make a
- BOB with a line like "NGI -b df1:brush/dude2 sys:dude2.s BowLeg2" i.e.
- "NGI <option(s)> <brush> <output> <struct>" -- we like mouse-driven
- code, but the simplest way is always the best -- always the tricky
- part of providing programs that are flexible.
-
- /****************************************************************/
- /******* Recompiling NGI ****************************************/
- /****************************************************************/
-
- NGI was written in C, using the Lattice 3.10 compiler under WorkBench 1.2.
- Much of its size (about 36K) is actually just the various structures
- and ImageData blocks, with the code being pretty short -- the IFF reader
- is probably more than half of the code. NGI used the Lattice "-a" option,
- so it should run properly on heavily-expanded machines, loading all ImageData
- into CHIP memory. Bon appetit bitblt.
-
- NGI's original source is included in the Source Directory of the Distribution
- Disk. EXECUTE the "NRestore.cmd" command file to load the various modules
- onto your SYS: disk, then "NGI.cmd" to execute & link. MAKE fans may want
- their own scripts, though "NGI.cmd" uses the -M option of lc to ensure that
- only revised .c modules are indeed compiled. If you want to change the look of
- the buttons, you'll find the original IFF brushes in the Brush directory.
-
- - KAB 1 June 87 1987
-
- /****************************************************************/
- /******* National Pixel Products ********************************/
- /****************************************************************/
-
- About National Pixel Products:
-
- National Pixel Products was created by ex-employees of the late,
- great Digital Productions/Robert Abel & Associates/Omnibus Simulation;
- makers of supercomputer graphics for the entertainment industry. While the
- Amiga is no Cray, we all think it's the hottest box on the block, even AFTER
- the Mac-2. Accept no substitutes.
-
- Future projects include a high-quality scan-line renderer (MUCH faster
- than ray-tracing) and other multi-purpose graphics tools like NGI -- we are
- also working on the adaptation of William Gibson's cyberpunk novel NEUROMANCER
- as an Amiga game.
-
- (Deluxe Paint and Deluxe Paint 2 are trademarks of Electronic Arts.
- Aegis and Aegis Images are trademarks of Aegis Development. DigiView
- is a trademark of NewTek, Inc. Amiga and Workbench are trademarks of
- Commodore Business Machines. Why are you reading this? Lattice is a
- trademark of Lattice, Inc.)
-
- /****************************************************************/
- /******** NGI Updates and Source Code ***************************/
- /****************************************************************/
-
- For updates, revenge, and complete source of NGI with examples of use
- (and to be on our mailing list, of course), send $25 to:
-
- National Pixel Products
- 25724 Salceda Road
- Valencia, California 91355
-
- /****************************************************************/
- /******************************************************** eof ***/
- /****************************************************************/
-